From a798edc360bc49190034e9b2c0713996eaf16b38 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jonas=20=C3=85dahl?= Date: Wed, 2 Dec 2020 17:42:42 +0100 Subject: [PATCH] gtk/window: Only deal with shadow when (ex|in)cluding csd size The size should correspond what gtk_widget_measure() does, and it measures what's within the window excluding the shadow; so make this helper function correspond to this. --- gtk/gtkwindow.c | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c index 5f7e363c22..4660dd40ce 100644 --- a/gtk/gtkwindow.c +++ b/gtk/gtkwindow.c @@ -3307,19 +3307,6 @@ gtk_window_update_csd_size (GtkWindow *window, w = *width + apply * (window_border.left + window_border.right); h = *height + apply * (window_border.top + window_border.bottom); - if (priv->title_box != NULL && - gtk_widget_get_visible (priv->title_box) && - gtk_widget_get_child_visible (priv->title_box)) - { - int minimum_height; - int natural_height; - - gtk_widget_measure (priv->title_box, GTK_ORIENTATION_VERTICAL, -1, - &minimum_height, &natural_height, - NULL, NULL); - h += apply * natural_height; - } - /* Make sure the size remains acceptable */ if (w < 1) w = 1; -- 2.30.2